<?php
$function = $_REQUEST ['function'];
$decodedParam = str_replace ( '&quot;', '"', $_REQUEST ['param'] );
$unserializedParam = unserialize ( $decodedParam );
$params = array ();
foreach ( $unserializedParam as &$value ) {
	$params [] = &$value;
}
if (! function_exists ( $function )) {
	echo  'undefined function x[' . $function . ']';
	exit();
}
$myResult = call_user_func_array ( $function, $params );
$result = array (
		'result' => $myResult,
		'params' => $params 
);
echo serialize ( $result );
exit ();

/** 動作確認用テストファンクション */
function testUserFunc2(&$a, &$b) {
	$a = 1;
	$b = 2;
	return 3;
}